//
//  RanCollectionViewLayout.m
//  ThusMyStyle
//
//  Created by Ran on 15/11/11.
//  Copyright (c) 2015年 gintong. All rights reserved.
//

#import "RanCollectionViewLayout.h"

@interface RanCollectionViewLayout()

@property(nonatomic, strong)NSDictionary *layoutInformation;

@property(nonatomic, assign)NSInteger maxNumRows;

@property(nonatomic, assign)UIEdgeInsets insets;

@end

@implementation RanCollectionViewLayout

- (instancetype)init
{
    self = [super init];
    if (self) {
        self.insets = UIEdgeInsetsMake(0, 0, 0, 0);
    }
    return self;
}

- (void)prepareLayout
{
    [super prepareLayout];
    
    NSMutableDictionary *layoutInfomation = [NSMutableDictionary dictionary];
    NSMutableDictionary *cellInformation = [NSMutableDictionary dictionary];
    NSIndexPath *indexPath;
    NSInteger numSections = [self.collectionView numberOfSections];
    for (NSInteger section = 0; section < numSections; section++) {
        NSInteger numItems = [self.collectionView numberOfItemsInSection:section];
        for (NSInteger item = 0; item < numItems; item++) {
            indexPath = [NSIndexPath indexPathForItem:item inSection:section];
            UICollectionViewLayoutAttributes *attributes = [self layoutAttributesForItemAtIndexPath:indexPath];
            [cellInformation setObject:attributes forKey:indexPath];
        }
    }
    

    
}



@end
